﻿using UnityEngine;
using iTManager;

public class Welcome : MonoBehaviour {
	[SerializeField] private tk2dSprite press;
	// Use this for initialization
	void Start () {
		ChangeColor();
	}
	
	// Update is called once per frame
	void Update () {
		if(Input.anyKeyDown){
			Application.LoadLevel("Menu");
		}
	}
	private void ChangeColor()
	{
		
		iTManager.iTweenBase.ValueTo(press.gameObject, iTManager.iTweenBase.Hash("from", 1, "to", 0, "looptype", "pingpong", "onupdate", "Alpha", "onupdatetarget",gameObject));
	}
	
	
	
	private void Alpha(float alpha_)
	{        
		
		Color c = new Color(1, 1, 1, alpha_);
		press.color = c;
		
	}
}
